package no.uib.kwikktaim.core;

import java.io.File;
import java.io.Serializable;


import javax.swing.DefaultListModel;

/**
 * This class is a class used for saving information in a serialized way to a file.
 * The playlist and current folder are some of the things saved.
 * @author tol060
 *
 */
public class SerializingBean implements Serializable {

	private static final long serialVersionUID = 1L;
	DefaultListModel playlist;
	int volum;
	private String currentFolder;

	/**
	 * Sets default volume. Is only used if there does not exist a serializingbean.
	 */
	public SerializingBean() {
		playlist = new DefaultListModel();
		volum = 80;
	}

	/**
	 * Returns the playlist
	 * @return
	 */
	public DefaultListModel getPlaylist() {
		return playlist;
	}

	/**
	 * Sets the playlist
	 * @param playlist
	 */
	public void setPlaylist(DefaultListModel playlist) {
		this.playlist = playlist;
	}

	/**
	 * Gets current volume
	 * @return
	 */
	public int getVolum() {
		return volum;
	}

	/**
	 * Sets volume in bean
	 * @param volum
	 */
	public void setVolum(int volum) {
		this.volum = volum;
	}

	/**
	 * Gets selected folder (in the JOptionPane for selecting files)
	 * @return
	 */
	public String getCurrentFolder() {
		return currentFolder;
	}

	/**
	 * Sets selected folder (in the JOptionPane for selecting files)
	 * @param currentFolder
	 */
	public void setCurrentFolder(String currentFolder) {
		this.currentFolder = currentFolder;
	}
}
